// const { defineConfig } = require('@vue/cli-service')
// module.exports = defineConfig({
//   transpileDependencies: true,
//   lintOnSave:false,
// })
// const NodePolyfillPlugin = require('node-polyfill-webpack-plugin')

module.exports = {
  outputDir: "dist1", //构建输出目录
  assetsDir: "assets", //静态资源目录
  lintOnSave: false, //是否开启eslint保存检测
  runtimeCompiler: true,
  // configureWebpack: {
  //   plugins: [new NodePolyfillPlugin()],
  // },

  devServer: {
    open: true, //配置自动启动浏览器
    host: "localhost",
    https: false,
    port: 9090,
    // 配置跨域-请求后端的接口
    client: {
      overlay: false
    },
    proxy: {
      '/api': {
         target: "http://localhost:8080", //对应自己的接口
        //target: "http://58.49.237.214:8080",// 服务器
        // target: "http://42.194.189.207:8080/",
        changeOrigin: true,
        ws: true,
        pathRewrite: {
          '^/api': ''
        }
      }
    }
  }
}



